<script language="JavaScript">
<!--
function Menu(cible,Objet)
{
	eval(cible+".location='"+Objet.options[Objet.selectedIndex].value+"'");
}
//-->
</script>
<table><tr>
<td>
<?php
$req_cat = $bdd->query('SELECT * FROM galeries ORDER BY nom');
?>
<select id="categorie" name="categorie" onChange="Menu('parent',this)">
	<optgroup label="Catégories">
	<?php
	while ($donnees_cat = $req_cat->fetch())
	{
		?>
		<option value="index.php?page=galeries&cat=<?php echo $donnees_cat['id']; ?>"><?php echo $donnees_cat['nom']; ?></option> 
		<?php
	}
	?>
	</optgroup>
</select>
</td><td>
<?php
if ((isset($_SESSION['identifiant'])) AND (!empty($_GET['id'])))
{
	?>
	<form method="post" action="index.php?page=admin_images">
		<input type="hidden" name="id" value="<?php echo $_GET['id']; ?>">
		<input type="submit" value="Editer" name="editer" class="bouton" />
		<input type="submit" value="Nouvelle images" name="nouveau" class="bouton" />
	</form>
	<?php
}
?>
</td></tr></table>
<hr/>